#include "SFMLSound.h"

using namespace vn;

SFMLSound::SFMLSound(void)
{
}


SFMLSound::~SFMLSound(void)
{
}

void SFMLSound::setSoundBuffer(const sf::SoundBuffer& p_soundBuffer)
{
	m_sound.setBuffer(p_soundBuffer);
}

void SFMLSound::play()
{
	m_sound.play();
}

void SFMLSound::stop()
{
	m_sound.stop();
}

void SFMLSound::pause()
{
	m_sound.pause();
}

float SFMLSound::getVolume()
{
	return m_sound.getVolume();
}

float SFMLSound::getPitch()
{
	return m_sound.getPitch();
}

bool SFMLSound::getLoop()
{
	return m_sound.getLoop();
}

void SFMLSound::setPitch(float p_pitch)
{
	m_sound.setPitch(p_pitch);
}

void SFMLSound::setLoop(bool p_value)
{
	m_sound.setLoop(p_value);
}

void SFMLSound::setVolume(float p_volume)
{
	m_sound.setVolume(p_volume);
}

vn::AudioState SFMLSound::getAudioState()
{
	sf::Sound::Status status = m_sound.getStatus();
	vn::AudioState state = static_cast<vn::AudioState>(status);
	return state;
}
